BIN=process
CC=gcc -std=c99
SRC=$(wildcard *.c)
OBJ=$(SRC:.c=.o)
LFLAGS=-o
FLAGS=-c
RM=rm -f

$(BIN):$(SRC)
	@$(CC) $(LFLAGS) $@ $^
	@echo "linking ... $^ to $@"

%.o:%.c
	@$(CC) $(FLAGS) $<
	@echo "compling ... $< to $@"

.PHONY:clean
clean:
	$(RM) $(OBJ) $(BIN)


